<%-- 
    Document   : talk2
    Created on : 2014/8/12, 下午 04:35:41
    Author     : gjun
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>JSP Page</title>
    </head>
    <body>
        <form action="TalkServlet" method="post" target="abc">
            <%= session.getAttribute("user") %>:<input type="text" name="mes">
            <input type="submit" value="說話">
        </form>
            <iframe src="talk3.jsp" width="300" height="300" id="abc" name="abc"></iframe>    
            <script>
               setInterval(function(){document.getElementById("abc").src="talk3.jsp"}, 3000);

            </script>
    
    </body>
</html>